package com.coolbi.security.dao;

import java.util.List;
import java.util.Map;

import com.coolbi.security.entity.User;
import com.coolbi.security.entity.UserGroup;
import com.coolbi.security.entity.UserToGroup;

public interface UserToGroupDao extends SimpleDao<UserToGroup> {

	/**根据用户组ID查询并分页*/
	List<User> findUserByGroupId(Map<String, Object> parameter, int offset, int limit);
	/**根据用户ID查询用户组*/
	List<UserGroup> findGroupByUserId(long id);
	/**根据用户组ID删除*/
	int deleteByGroupId(long id);
	/** 批量插入数据*/
	int saveByBatch(Long userId, List<Long> groupIds);
}
